package 面向对象.实验六;


/**
 * @projectName: JAVA编程
 * @package: 面向对象.实验六
 * @className: MyComparatorForName
 * @author: hhy帅
 * @description: TODO
 * @date: 2021/11/7 20:50
 */
public class MyComparatorForName extends Book implements Comparable{
    public  MyComparatorForName(String isbn,String title,String author){

        super(isbn,title,author);
    }

    @Override
    public int compareTo(Object o) {
        return getIbsn().compareTo(((Book)o).getIbsn());
    }
}
